home *** CD-ROM | disk | FTP | other *** search
/ Aminet 31 / Aminet 31 (1999)(Schatztruhe)[!][Jun 1999].iso / Aminet / dev / basic / UDP_Chat.lha / UDPChat / net_protocol_header.bb2 < prev    next >
Text File  |  1999-03-29  |  3KB  |  1 lines

  1. ;;   Network Protocol Includes V 0.4  03/01/1999;      by  Anton ReinauerNET_PROTOCOL_VERSION.s=܆(1)                   ; Net protocol version 0.1#NET_PROTOCOL_VERSION=$01; Control Packet Constants  (2 bytes with first byte=1)CONTROL_PACKET.s=܆($1)              ; Byte header for Control Packet#CONTROL_PACKET=$1              ; Byte header for Control PacketCP_REQ_CONNECT.s=CONTROL_PACKET.s + Ü†($1)   ; Connection request#CP_REQ_CONNECT=$1CP_REP_ACCEPT.s=CONTROL_PACKET.s + Ü†($81)    ; Connection accepted#CP_REP_ACCEPT=$81CP_REP_REJECT.s=CONTROL_PACKET.s + Ü†($82)    ; Server refuses connection#CP_REP_REJECT=$82CP_REQ_SERVER_INFO.s=CONTROL_PACKET.s + Ü†($2) ; Client requests info from Server#CP_REQ_SERVER_INFO= $2CP_SERVER_INFO.s=CONTROL_PACKET.s + Ü†($83)   ; Info from Server#CP_SERVER_INFO=$83CP_REQ_PLAYER_INFO.s=CONTROL_PACKET.s + Ü†($3) ; Request info on a player from Server#CP_REQ_PLAYER_INFO=$3CP_REP_PLAYER_INFO.s=CONTROL_PACKET.s + Ü†($84) ; Player info reply from server#CP_REP_PLAYER_INFO=$84CP_REQ_ENVIRONMENT_INFO.s=CONTROL_PACKET.s + Ü†($4) ; Request game environment details#CP_REQ_ENVIRONMENT_INFO=$4CP_REP_ENVIRONMENT_INFO.s=CONTROL_PACKET.s + Ü†($85) ; Game environment details from Server#CP_REP_ENVIRONMENT_INFO=$85CP_REQ_PLAYER_DISCONNECT.s=CONTROL_PACKET.s + Ü†($5) ; Client tells Server if it can't contact another player#CP_REQ_PLAYER_DISCONNECT=$5CP_REP_PLAYER_DISCONNECTED.s=CONTROL_PACKET.s + Ü†($86) ; Server tells a client if a player has disconnected#CP_REP_PLAYER_DISCONNECTED=$86CP_END_GAME.s=CONTROL_PACKET.s + Ü†($6) ; Server tells client the game has ended#CP_END_GAME=$6CP_END_GAME_REC.s=CONTROL_PACKET.s + Ü†($87) ; Client confirms it has received Game End packet#CP_END_GAME_REC=$87; Game Packet Constants  (1 byte from $02 onwards, then a 4 byte packet number;                         and then data depending on game packet type).#REL_STRING_MESSAGE=$02   ; Communication string from one player to anotherREL_STRING_MESSAGE.s=܆($2)  ; - only used if message >1024 bytes#REL_STRING_END=$03       ; End of communication string, and used if messageREL_STRING_END.s=܆($3) ; is <=1024 bytes#REL_PACKET_ACK=$04       ; Acknowledgement that a packet (of packet number)REL_PACKET_ACK.s=܆($4) ; has been received#PING_REQUEST=$05         ; Send a Ping Request to Server/another playerPING_REQUEST.s=܆($5)#PING_RESPONSE=$06        ; Response to a Ping request from a Server/another playerPING_RESPONSE.s=܆($6)  ;#UNRELIABLE_PACKET=$07    ; Unreliable string message- can't be >1024 bytes